
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>Form Presensi</title>
        <script type="text/javascript" src="<?php echo base_url() ?>js/jquery-1.5.2.min.js"></script> 
        <script type="text/javascript" src="<?php echo base_url() ?>js/cufon-yui.js"></script>
        <script type="text/javascript" src="<?php echo base_url() ?>js/Myriad_Pro_400-Myriad_Pro_700.font.js"></script>
        <script type="text/javascript" >
            Cufon.replace('.myd');
        </script>

        <link rel="stylesheet" type="text/css" href="<?php echo base_url() ?>css/absen.css"/>


    </head>


    <body>
        <p class="ih atasp">ComLabs USDI ITB | Presensi Peserta Pelatihan Reguler | Term-<?php echo $term.' '.$tahun?></p>
        <table id="bingkaitop"  width="100%" border="0" cellspacing="0" cellpadding="5">
            <tr>
                <td> 
                    <table border="0" cellpadding="0" cellspacing="0" id="head80">
                        <tr>
                            <td class="ketabsen">Presensi Peserta</td>
                            <td class="ketabsen"><?php echo $kode?>-<?php echo $angkatan?></td>
                            <td width="275" class="ketabsen"><?php echo $nama_pelatihan?></td>
                            <td><table width="100%" border="0" cellpadding="0" cellspacing="0" class="" id="head95">
                                    <tr>
                                        <td class=" ketabsen uh"> Kelas/Angkatan: <span class="diegodora"><?php echo $angkatan?></span></td>
                                    </tr>
                                    <tr>
                                        <td class=" ketabsen uh">Nama Instruktur:  
                                            <span class="diegodora">
                                                <?php for($i=0;$i<count($ins);$i++){
                                                    echo $ins[$i];
                                                    if($i<count($ins)-1){
                                                        echo ', ';
                                                    }
                                                }?>
                                            </span>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="ketabsen uh eh"> Durasi/Sesi:  <span class="diegodora"><?php echo $jam_total?> jam/<?php echo $jum_sesi?> Sesi</span></td>
                                    </tr>
                                </table></td>
                        </tr>
                    </table></td>
                <td width="140"><img id="logoterm" src="<?php echo $logo_term?>" width="166" height="68" /></td>
                <td width="101"><img id="logocic" src="<?php echo base_url()?>images/logocic.png" width="620" height="350" /></td>
            </tr>
        </table>
        <table id="absen" width="100%" border="0" cellspacing="0" cellpadding="0">
            <tr>
                <th class="thsmall" width="4%">No</th>
                <th class="thsmall" width="8%">ComLabs ID</th>
                <th class="thsmall" width="28%">Nama Lengkap</th>
                <?php
                    if($hal*6>$jum_sesi){
                        $max=$jum_sesi;
                    }else{
                        $max=$hal*6;
                    }
                ?>
                <?php for($i=(($hal-1)*6);$i<$max;$i++){?>
                <?php 
                    $no_sesi = $i+1;
                    $jadwal = $this->db->get_where('daftar_jadwal',array('KODE_PELATIHAN'=>$kode,'ANGKATAN'=>$angkatan,'NOMOR_SESI'=>$no_sesi));
                    $hari='-';
                    $tanggal='-';
                    if($jadwal->num_rows()==1){
                        $waktu=$jadwal->row()->TANGGAL;
                        $waktu = $this->date_func->date_konversion_format5($waktu);
                        $hari=$waktu['day'];
                        $tanggal=$waktu['date'];
                    }
                ?>
                <th width="10%" class="thsmall">
                    Sesi-<?php echo $no_sesi?>
                    <span><?php echo $hari?></span>
                    <span><?php echo $tanggal?></span>
                </th>
                <?php } ?>
            </tr>
            <?php for($i=0;$i<count($peserta);$i++){?>
            <tr>
                <td class="cen"><?php echo ($i+1)?></td>
                <td class="cen"><?php echo $peserta[$i]['NO_CIC_CARD']?></td>
                <td><?php echo $peserta[$i]['NAMA']?></td>
                <?php for($x=($hal-1)*6;$x<$max;$x++){?>
                <td class="cen">&nbsp;</td>
                <?php } ?>
            </tr>
            <?php } ?>
        </table>

        <p>Mohon diperhatikan : <br />
            Persentase presensi akan dicantumkan di sertifikat, syarat mendapatkan sertifikat adalah dengan kehadiran minimal 75%<br />
            Jika ada kesalahan nama harap diperbaiki di lembar presensi ini.<br/>
            Printed on <?php echo date('M d, Y') . ', ' . date('H.m A') ?>.</p>

    </body>
</html>
